package visitorPattern;

//具体访问者类：导出访问者
public class ExportVisitor implements Visitor {
    @Override
    public void visit(TextElement textElement) {
        System.out.println("导出文本："+textElement.getText());
    }

    @Override
    public void visit(ImageElement imageElement) {
         System.out.println("导出图片："+imageElement.getImagePath());
    }
}
